/*
 * @Description: 基础路由配置
 * @Author: wangfuwei
 * @Date: 2020-11-30 16:52:40
 * @LastEditors: wangfuwei
 * @LastEditTime: 2021-04-22 20:16:27
 * @FilePath: /horizon-frontend/src/router/config.js
 */
/**
 * 基础路由
 * @type { *[] }
 */
export const constantRouterMap = [
  {
    path: "/",
    component: () => import(/* webpackChunkName: "layout" */ "@/layouts/BasicLayout"),
    redirect: "/index",
    children: [
      {
        path: "index",
        name: "index",
        component: () => import(/* webpackChunkName: "index" */ "@/views/index"),
        describe: "首页",
      },
      {
        path: "apps",
        name: "apps",
        component: () => import(/* webpackChunkName: "index" */ "@/views/apps"),
        describe: "应用",
      },
    ],
  },
  {
    path: "/user",
    component: () => import(/* webpackChunkName: "layout" */ "@/layouts/UserLayout"),
    redirect: "/user/login",
    children: [
      {
        path: "login",
        name: "login",
        component: () => import(/* webpackChunkName: "user" */ "@/views/user/Login"),
        describe: "登录",
      },
    ],
  },

  {
    path: "/baseService",
    component: () => import(/* webpackChunkName: "layout" */ "@/layouts/BasicLayout"),
    redirect: "/baseService/index",
    children: [
      {
        path: "index",
        name: "index",
        component: () => import(/* webpackChunkName: "index" */ "@/views/baseService"),
      },
      {
        path: "person",
        name: "person",
        component: () => import(/* webpackChunkName: "index" */ "@/views/baseService/person"),
      },
      {
        path: "sysorg",
        name: "sysorg",
        component: () => import(/* webpackChunkName: "index" */ "@/views/baseService/sysorg"),
      },
      {
        path: "sysorgli",
        name: "sysorgli",
        component: () => import(/* webpackChunkName: "index" */ "@/views/baseService/sysorgli"),
      },
      {
        path: "sysorgrole",
        name: "sysorgrole",
        component: () => import(/* webpackChunkName: "index" */ "@/views/baseService/sysorgrole"),
      },
    ],
  },
  {
    path: "/devPlatform",
    component: () => import(/* webpackChunkName: "layout" */ "@/layouts/BasicLayout"),
    redirect: "/devPlatform/index",
    children: [
      {
        path: "index",
        name: "index",
        component: () => import(/* webpackChunkName: "index" */ "@/views/devPlatform"),
      },
    ],
  },
  {
    path: "/403",
    component: () => import(/* webpackChunkName: "fail" */ "@/views/exception/403"),
  },
  {
    path: "/404",
    component: () => import(/* webpackChunkName: "fail" */ "@/views/exception/404"),
  },
  {
    path: "/500",
    component: () => import(/* webpackChunkName: "fail" */ "@/views/exception/500"),
  },
  {
    path: "*",
    redirect: "/404",
  },
];
